<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://xmlns.jcp.org/jsf/core">
    <h:head>
        <title>Day Specification</title>
    </h:head>
    <h:body>
        <p:layout fullPage="true">
            <p:layoutUnit position="north" size="100" style="border: 0px">
                <h:panelGrid columns="3" style="width: 100%">
                    <h:graphicImage value="/images/Simbolo_Meteocal.png" height="100"></h:graphicImage>
                    <h1>Welcome back</h1>
                    <h:button outcome="eventcreation" value="Create a new Event" />
                </h:panelGrid>
            </p:layoutUnit> 
            <p:layoutUnit position="center">
                <div style="height: 40px">
                    <h1>DATE</h1>
                </div>
                <h:form>
                    <h:panelGrid columns="2" style="width: 100%">
                        <h:outputLabel value="#{daySpecificationBean.getEventname(0)}" id="nome0"/>
                        <h:outputLabel value="#{daySpecificationBean.getEventWea(0)}" id="weather0"/>
                        <h:outputText value="#{daySpecificationBean.getEventDesc(0)}" id="desc0"/>
                        <h:button value="More info on the event?" outcome="eventdetail"/>
                    </h:panelGrid>
                    <hr/>
                    <h:panelGrid columns="2" style="width: 100%">
                        <h:outputLabel value="#{daySpecificationBean.getEventname(1)}" id="nome1"/>
                        <h:outputLabel value="#{daySpecificationBean.getEventWea(1)}" id="weather1"/>
                        <h:outputText value="#{daySpecificationBean.getEventDesc(1)}" id="desc1"/>
                        <h:button value="More info on the event?" outcome="eventdetail"/>
                    </h:panelGrid>
                    <hr/>
                    <h:panelGrid columns="2" style="width: 100%">
                        <h:outputLabel value="#{daySpecificationBean.getEventname(2)}" id="nome2"/>
                        <h:outputLabel value="#{daySpecificationBean.getEventWea(2)}" id="weather2"/>
                        <h:outputText value="#{daySpecificationBean.getEventDesc(2)}" id="desc2"/>
                        <h:button value="More info on the event?" outcome="eventdetail"/>
                    </h:panelGrid>
                    <hr/>
                    <h:panelGrid columns="2" style="width: 100%">
                        <h:outputLabel value="#{daySpecificationBean.getEventname(3)}" id="nome3"/>
                        <h:outputLabel value="#{daySpecificationBean.getEventWea(3)}" id="weather3"/>
                        <h:outputText value="#{daySpecificationBean.getEventDesc(3)}" id="desc3"/>
                        <h:button value="More info on the event?" outcome="eventdetail"/>
                    </h:panelGrid>
                    <hr/>
                    <h:panelGrid columns="2" style="width: 100%">
                        <h:outputLabel value="#{daySpecificationBean.getEventname(4)}" id="nome4"/>
                        <h:outputLabel value="#{daySpecificationBean.getEventWea(4)}" id="weather4"/>
                        <h:outputText value="#{daySpecificationBean.getEventDesc(4)}" id="desc4"/>
                        <h:button value="More info on the event?" outcome="eventdetail"/>
                    </h:panelGrid>
                    <hr/>
                    
                </h:form>
                <hr/>
                <h:panelGrid columns="3" style="width: 100%">
                    <h:form>
                        <p:commandButton value="update">
                            <f:ajax render="name0"/>
                            <f:ajax render="weather0"/>
                            <f:ajax render="desc0"/>
                            <f:ajax render="name1"/>
                            <f:ajax render="weather1"/>
                            <f:ajax render="desc1"/>
                            <f:ajax render="name2"/>
                            <f:ajax render="weather2"/>
                            <f:ajax render="desc2"/>
                            <f:ajax render="name3"/>
                            <f:ajax render="weather3"/>
                            <f:ajax render="desc3"/>
                            <f:ajax render="name4"/>
                            <f:ajax render="weather4"/>
                            <f:ajax render="desc4"/>
                        </p:commandButton>
                        <h:commandButton id = "prev" value="Previous five" action="#{daySpecificationBean.prev}">
                            <f:ajax render="name0"/>
                            <f:ajax render="weather0"/>
                            <f:ajax render="desc0"/>
                            <f:ajax render="name1"/>
                            <f:ajax render="weather1"/>
                            <f:ajax render="desc1"/>
                            <f:ajax render="name2"/>
                            <f:ajax render="weather2"/>
                            <f:ajax render="desc2"/>
                            <f:ajax render="name3"/>
                            <f:ajax render="weather3"/>
                            <f:ajax render="desc3"/>
                            <f:ajax render="name4"/>
                            <f:ajax render="weather4"/>
                            <f:ajax render="desc4"/>
                        </h:commandButton>
                        <h:commandButton id = "next" value="Next five" action="#{daySpecificationBean.next}">
                            <f:ajax render="name0"/>
                            <f:ajax render="weather0"/>
                            <f:ajax render="desc0"/>
                            <f:ajax render="name1"/>
                            <f:ajax render="weather1"/>
                            <f:ajax render="desc1"/>
                            <f:ajax render="name2"/>
                            <f:ajax render="weather2"/>
                            <f:ajax render="desc2"/>
                            <f:ajax render="name3"/>
                            <f:ajax render="weather3"/>
                            <f:ajax render="desc3"/>
                            <f:ajax render="name4"/>
                            <f:ajax render="weather4"/>
                            <f:ajax render="desc4"/>
                        </h:commandButton>
                    </h:form>
                </h:panelGrid>
            </p:layoutUnit>
            <p:layoutUnit position="west" size="400">
                Today's event
               
            </p:layoutUnit>
            <p:layoutUnit position="south" size="60">
                <h:panelGrid columns="3" style="width: 100%">
                    <h:button outcome="contacts" value="Search for a user" />
                    
                    <h:button outcome="notifications" value="Move to your notifications page" />
                    
                    <h:button outcome="index" value="Logout" />
                </h:panelGrid>
            </p:layoutUnit>
        </p:layout>
    </h:body>
</html>

